import request from '@/axios';

export const getList = (positionInstanceId) => {
  return request({
    url: '/position/positionUser/list',
    method: 'get',
    params: {
      positionInstanceId
    }
  })
}

export const getDetail = (id) => {
  return request({
    url: '/position/positionUser/detail',
    method: 'get',
    params: {
      id
    }
  })
}

export const remove = (ids) => {
  return request({
    url: '/position/positionUser/remove',
    method: 'post',
    params: {
      ids,
    }
  })
}

export const add = (row) => {
  return request({
    url: '/position/positionUser/save',
    method: 'post',
    data: row
  })
}

export const update = (row) => {
  return request({
    url: '/position/positionUser/update',
    method: 'post',
    data: row
  })
}

export const dismiss = (ids) => {
  return request({
    url: '/position/positionUser/dismiss',
    method: 'post',
    params: {
      ids
    }
  })
}